<?php namespace Zmsun\View\Module\Param;class Scope extends AParam{private$value=[];public function getValue(){return json_decode($this->xmlElement,true);}public function setValue($value){$this->xmlElement[0]=$value;}public function getHtml(){$label=$this->getAttribute('label');$name=$this->getAttribute('name');$tips=$this->getTipsHtml($this->getAttribute('description'));$this->value=$this->getValue();if(isset($this->value['min'])){$value1=$this->value['min'];}else{$value1="";}if(isset($this->value['max'])){$value2=$this->value['max'];}else{$value2="";}return <<<S
		<div class="control-group">
			<label class="control-label" for="">{$label}</label>
			<div class="control">
				<input type="hidden" autocomplete="off" name="{$name}" class="scope-deal">
				<input class="input-box scope-input-min-{$name} scope-input" type="text" value="{$value1}">
				<div class="scope-split">---</div>
				<input class="input-box scope-input-max-{$name} scope-input" type="text" value="{$value2}">
				{$tips}
			</div>
		</div>
S;
}}?>